local skel = fk.CreateSkill {
  name = "rmt__kongshu",
  tags = {Skill.Compulsory},
}

Fk:loadTranslationTable{
  ["rmt__kongshu"] = "空输",
  [":rmt__kongshu"] = "锁定技，若你手牌/体力最大，手牌/体力最小且小于你的角色手牌对你可见。",

  ["$rmt__kongshu1"] = "不能再犹豫了，必须要出重拳。",
  ["$rmt__kongshu2"] = "不惧怕空输的威力，已经不是一般老百姓了，这明显全都是暴徒。",
}

skel:addEffect("visibility", {
  card_visible = function(self, player, card)
    if player:hasSkill(skel.name) then
      local room = Fk:currentRoom()
      local owner = room:getCardOwner(card.id)
      if owner and table.contains(owner.player_cards[Player.Hand], card.id) then
        if owner.hp < player.hp
        and table.every(room.alive_players, function(p) return p.hp <= player.hp end)
        and table.every(room.alive_players, function(p) return p.hp >= owner.hp end) then
          return true
        end
        if owner:getHandcardNum() < player:getHandcardNum() and
        table.every(room.alive_players, function(p) return p:getHandcardNum() <= player:getHandcardNum() end)
        and table.every(room.alive_players, function(p) return p:getHandcardNum() >= owner:getHandcardNum() end) then
          return true
        end
      end
    end
  end
})

return skel
